home *** CD-ROM | disk | FTP | other *** search
/ How Would You Survive? / How Would You Survive (1995)(Grolier)[Mac-PC].iso / mac / SHARED.DIR / 01960_Script_TOC Buttons < prev    next >
Text File  |  1995-09-13  |  9KB  |  244 lines

  1. Global gBtn1, gBtn2, gBtn3, gBtn4, gBtn5, gBtn6, gBtn7, gBtn8, gBtn9, ¼
  2. gBtn16, gBtn17, gBtn18, gNewMarker, gBtnTOC1, gBtnTOC2, gBtnTOC3, gBtnTOC4, ¼
  3. gBtnTOC5, gBtnTOC6, gBtnTOC7, gBtnTOC8, gBtnTOC9, gBtnTOC10, gBtnTOC11, ¼
  4. gBtnTOC12, gBtnTOC13, gBtnTOC14, gBtnTOC15, gBtnTOC16,gTheHelpIsOn
  5.  
  6. -----------------------------------------------------------------------------
  7. on ATOCSetUp
  8.   set ScriptNumber = the number of cast "a3StateButton"
  9.   set gBtnTOC1 = birth(script ScriptNumber, 4, 40, 0, "YourHome", "HandCursor")
  10.   set gBtnTOC2 = birth(script ScriptNumber, 5, 43, 0, "YourFamily", "HandCursor")
  11.   set gBtnTOC3 = birth(script ScriptNumber, 6, 46, 0, "LivingFarmer", "HandCursor")
  12.   set gBtnTOC4 = birth(script ScriptNumber, 7, 49, 0, "Workshops", "HandCursor")
  13.   set gBtnTOC5 = birth(script ScriptNumber, 8, 52, 0, "Clothes", "HandCursor")  
  14.   set gBtnTOC6 = birth(script ScriptNumber, 9, 55, 0, "Market", "HandCursor")
  15.   set gBtnTOC7 = birth(script ScriptNumber, 10, 58, 0, "Entertainment", "HandCursor")
  16.   set gBtnTOC8 = birth(script ScriptNumber, 11, 61, 0, "pharoahs", "HandCursor")
  17.   set gBtnTOC9 = birth(script ScriptNumber, 12, 64, 0, "Wars", "HandCursor")
  18.   set gBtnTOC10 = birth(script ScriptNumber, 13, 67, 0, "Sickness", "HandCursor")
  19.   set gBtnTOC11 = birth(script ScriptNumber, 14, 70, 0, "TheGods", "HandCursor")
  20.   set gBtnTOC12 = birth(script ScriptNumber, 15, 73, 0, "MeasuringTime", "HandCursor")
  21.   set gBtnTOC13 = birth(script ScriptNumber, 16, 76, 0, "EndofEmpire", "HandCursor")
  22.   set gBtnTOC14 = birth(script ScriptNumber, 17, 79, 0, "Food", "HandCursor")
  23. end
  24.  
  25. on AGlobalTOCRollover
  26.   if (the MouseV < 250) then
  27.     if hilightPullDown (gBtn1) then exit
  28.     if hilight (gBtn16) then exit
  29.     if hilight (gBtn18) then exit
  30.     if hilight (gBtnTOC1) then exit
  31.     if hilight (gBtnTOC2) then exit
  32.     if hilight (gBtnTOC4) then exit
  33.     if hilight (gBtnTOC5) then exit
  34.     if hilight (gBtnTOC8) then exit
  35.     if hilight (gBtnTOC9) then exit
  36.     if hilight (gBtnTOC12) then exit
  37.     if hilight (gBtnTOC13) then 
  38.       exit
  39.     end if
  40.   else
  41.     if rollover(38) then
  42.       if gTheHelpIsOn = 1 then
  43.         puppetsound "SA142100.AIF"
  44.         updatestage
  45.         repeat while rollover(38)
  46.           nothing
  47.         end repeat
  48.       end if
  49.       puppetsound 0
  50.     end if
  51.     if Donthilight (gBtn2) then exit
  52.     if Donthilight (gBtn3) then exit
  53.     if hilight (gBtn4) then exit
  54.     if hilight (gBtn5) then exit
  55.     if hilight (gBtn6) then exit
  56.     if hilight (gBtn7) then exit
  57.     if hilight (gBtn8) then exit
  58.     if hilight (gBtn9) then exit
  59.     if hilight (gBtnTOC3) then exit
  60.     if hilight (gBtnTOC6) then exit
  61.     if hilight (gBtnTOC7) then exit
  62.     if hilight (gBtnTOC10) then exit
  63.     if hilight (gBtnTOC11) then exit
  64.     if hilight (gBtnTOC14) then exit
  65.   end if
  66. end
  67.  
  68.  
  69. -----------------------------------------------------------------------------
  70. on ETOCSetUp
  71.   set ScriptNumber = the number of cast "a3StateButton"
  72.   set gBtnTOC1 = birth(script ScriptNumber, 4, 40, 0, "YourFamily", "HandCursor")
  73.   set gBtnTOC2 = birth(script ScriptNumber, 5, 43, 0, "YourHome", "HandCursor")
  74.   set gBtnTOC3 = birth(script ScriptNumber, 6, 46, 0, "Food", "HandCursor")
  75.   set gBtnTOC4 = birth(script ScriptNumber, 7, 49, 0, "Clothes", "HandCursor")
  76.   set gBtnTOC5 = birth(script ScriptNumber, 8, 52, 0, "Town", "HandCursor")  
  77.   set gBtnTOC6 = birth(script ScriptNumber, 9, 55, 0, "OnTheRiver", "HandCursor")
  78.   set gBtnTOC7 = birth(script ScriptNumber, 10, 58, 0, "LivingFarmer", "HandCursor")
  79.   set gBtnTOC8 = birth(script ScriptNumber, 11, 61, 0, "Workshops", "HandCursor")
  80.   set gBtnTOC9 = birth(script ScriptNumber, 12, 64, 0, "Careers", "HandCursor")
  81.   set gBtnTOC10 = birth(script ScriptNumber, 13, 67, 0, "pharoahs", "HandCursor")
  82.   set gBtnTOC11 = birth(script ScriptNumber, 14, 70, 0, "Women", "HandCursor")
  83.   set gBtnTOC12 = birth(script ScriptNumber, 15, 73, 0, "TheGods", "HandCursor")
  84.   set gBtnTOC13 = birth(script ScriptNumber, 16, 76, 0, "Entertainment", "HandCursor")
  85.   set gBtnTOC14 = birth(script ScriptNumber, 17, 79, 0, "Sickness", "HandCursor")
  86.   set gBtnTOC15 = birth(script ScriptNumber, 18, 82, 0, "Superstitions", "HandCursor")
  87.   set gBtnTOC16 = birth(script ScriptNumber, 19, 85, 0, "Mummifications", "HandCursor")
  88.   
  89. end
  90.  
  91. on EGlobalTOCRollover
  92.   if (the MouseV < 250) then
  93.     if hilightPullDown (gBtn1) then exit
  94.     if hilight (gBtn17) then exit
  95.     if hilight (gBtn18) then exit
  96.     if hilight (gBtnTOC1) then exit
  97.     if hilight (gBtnTOC2) then exit
  98.     if hilight (gBtnTOC5) then exit
  99.     if hilight (gBtnTOC6) then exit
  100.     if hilight (gBtnTOC9) then exit
  101.     if hilight (gBtnTOC10) then exit
  102.     if hilight (gBtnTOC13) then exit
  103.     if hilight (gBtnTOC14) then 
  104.       exit
  105.     end if
  106.   else
  107.     if rollover(38) then
  108.       if gTheHelpIsOn = 1 then
  109.         puppetsound "SE142100.AIF"
  110.         updatestage
  111.         repeat while rollover(38)
  112.           nothing
  113.         end repeat
  114.       end if
  115.       puppetsound 0
  116.     end if
  117.     if Donthilight (gBtn2) then exit
  118.     if Donthilight (gBtn3) then exit
  119.     if hilight (gBtn4) then exit
  120.     if hilight (gBtn5) then exit
  121.     if hilight (gBtn6) then exit
  122.     if hilight (gBtn7) then exit
  123.     if hilight (gBtn8) then exit
  124.     if hilight (gBtn9) then exit
  125.     if hilight (gBtnTOC3) then exit
  126.     if hilight (gBtnTOC4) then exit
  127.     if hilight (gBtnTOC7) then exit
  128.     if hilight (gBtnTOC8) then exit
  129.     if hilight (gBtnTOC11) then exit
  130.     if hilight (gBtnTOC12) then exit
  131.     if hilight (gBtnTOC15) then exit
  132.     if hilight (gBtnTOC16) then exit
  133.   end if
  134. end
  135.  
  136. -----------------------------------------------------------------------------
  137. on VTOCSetUp
  138.   set ScriptNumber = the number of cast "a3StateButton"
  139.   set gBtnTOC1 = birth(script ScriptNumber, 4, 649, 0, "YourFamily", "HandCursor")
  140.   set gBtnTOC2 = birth(script ScriptNumber, 5, 652, 0, "YourPlace", "HandCursor")
  141.   set gBtnTOC3 = birth(script ScriptNumber, 6, 655, 0, "YourHome", "HandCursor")
  142.   set gBtnTOC4 = birth(script ScriptNumber, 7, 658, 0, "Food", "HandCursor")
  143.   set gBtnTOC5 = birth(script ScriptNumber, 8, 661, 0, "Clothes", "HandCursor")  
  144.   set gBtnTOC6 = birth(script ScriptNumber, 9, 664, 0, "LivingFarmer", "HandCursor")
  145.   set gBtnTOC7 = birth(script ScriptNumber, 10, 667, 0, "Town", "HandCursor")
  146.   set gBtnTOC8 = birth(script ScriptNumber, 11, 670, 0, "Workshops", "HandCursor")
  147.   set gBtnTOC9 = birth(script ScriptNumber, 12, 673, 0, "OnTheRiver", "HandCursor")
  148.   set gBtnTOC10 = birth(script ScriptNumber, 13, 676, 0, "Market", "HandCursor")
  149.   set gBtnTOC11 = birth(script ScriptNumber, 14, 679, 0, "Careers", "HandCursor")
  150.   set gBtnTOC12 = birth(script ScriptNumber, 15, 682, 0, "pharoahs", "HandCursor")
  151.   set gBtnTOC13 = birth(script ScriptNumber, 16, 685, 0, "Travelling", "HandCursor")
  152.   set gBtnTOC14 = birth(script ScriptNumber, 17, 688, 0, "TheGods", "HandCursor")
  153.   set gBtnTOC15 = birth(script ScriptNumber, 18, 691, 0, "Sickness", "HandCursor")
  154.   set gBtnTOC16 = birth(script ScriptNumber, 19, 694, 0, "Mummifications", "HandCursor")
  155. end
  156.  
  157. on VGlobalTOCRollover
  158.   if (the MouseV < 250) then
  159.     if hilightPullDown (gBtn1) then exit
  160.     if hilight (gBtn17) then exit
  161.     if hilight (gBtn16) then exit
  162.     if hilight (gBtnTOC1) then exit
  163.     if hilight (gBtnTOC2) then exit
  164.     if hilight (gBtnTOC5) then exit
  165.     if hilight (gBtnTOC6) then exit
  166.     if hilight (gBtnTOC9) then exit
  167.     if hilight (gBtnTOC10) then exit
  168.     if hilight (gBtnTOC13) then exit
  169.     if hilight (gBtnTOC14) then 
  170.       exit
  171.     end if
  172.   else
  173.     if rollover(38) then
  174.       if gTheHelpIsOn = 1 then
  175.         puppetsound "SV142100.AIF"
  176.         updatestage
  177.       end if
  178.       repeat while rollover(38)
  179.         nothing
  180.       end repeat
  181.       puppetsound 0
  182.     end if
  183.     if Donthilight (gBtn2) then exit
  184.     if Donthilight (gBtn3) then exit
  185.     if hilight (gBtn4) then exit
  186.     if hilight (gBtn5) then exit
  187.     if hilight (gBtn6) then exit
  188.     if hilight (gBtn7) then exit
  189.     if hilight (gBtn8) then exit
  190.     if hilight (gBtn9) then exit
  191.     if hilight (gBtnTOC3) then exit
  192.     if hilight (gBtnTOC4) then exit
  193.     if hilight (gBtnTOC7) then exit
  194.     if hilight (gBtnTOC8) then exit
  195.     if hilight (gBtnTOC11) then exit
  196.     if hilight (gBtnTOC12) then exit
  197.     if hilight (gBtnTOC15) then exit
  198.     if hilight (gBtnTOC16) then exit
  199.   end if
  200. end
  201.  
  202.  
  203. -------------------------------
  204. on TOCKill
  205.   WatchCursor
  206.   hideControl (gBtnTOC1)
  207.   hideControl (gBtnTOC2)
  208.   hideControl (gBtnTOC3)
  209.   hideControl (gBtnTOC4)
  210.   hideControl (gBtnTOC5)
  211.   hideControl (gBtnTOC6)
  212.   hideControl (gBtnTOC7)
  213.   hideControl (gBtnTOC8)
  214.   hideControl (gBtnTOC9)
  215.   hideControl (gBtnTOC10)
  216.   hideControl (gBtnTOC11)
  217.   hideControl (gBtnTOC12)
  218.   hideControl (gBtnTOC13)
  219.   hideControl (gBtnTOC14)
  220.   if objectP (gBtnTOC15) then
  221.     hideControl (gBtnTOC15)
  222.     set gBtnTOC15 = 0 
  223.   end if
  224.   if objectP (gBtnTOC16) then
  225.     hideControl (gBtnTOC16)
  226.     set gBtnTOC16 = 0
  227.   end if
  228.   set gBtnTOC1 = 0
  229.   set gBtnTOC2 = 0
  230.   set gBtnTOC3 = 0
  231.   set gBtnTOC4 = 0
  232.   set gBtnTOC5 = 0
  233.   set gBtnTOC6 = 0
  234.   set gBtnTOC7 = 0
  235.   set gBtnTOC8 = 0
  236.   set gBtnTOC9 = 0
  237.   set gBtnTOC10 = 0
  238.   set gBtnTOC11 = 0
  239.   set gBtnTOC12 = 0
  240.   set gBtnTOC13 = 0
  241.   set gBtnTOC14 = 0
  242. end 
  243.  
  244.